.BG
.FN outer
.FN %o%
.TL
Generalized Outer Products
.CS
X %o% Y #operator form
outer(X, Y, FUN="*", ...)
.AG X,Y
first and second arguments to the function `FUN'.
Missing values (`NA's) are allowed if `FUN' accepts them.
.AG FUN
in the general form, some S function that takes at least two
vectors as arguments and returns a single value.
.AG ...
other arguments to `FUN', if needed.  The names of the arguments, if any,
should be those meaningful to `FUN'.
.RT
array, whose dimension vector is the concatenation of the
dimension vectors of `X' and `Y', and such
that `FUN(X[i,j,k,...], Y[a,b,c,...])' is the
value of the `[i,j,k,...,a,b,c,...]' element.
`outer' forms two arrays corresponding
to the data in `X' and `Y',
each of which has a `dim' attribute formed by concatenating the
`dim' attributes of `X' and `Y'.
It then calls `FUN' just once with these two arrays as arguments.
Therefore, `FUN' should be a function that operates on vectors or arrays
and expects (at least) two arguments.
.EX
z <- x %o% y   # The outer product array
  # dim(z) == c(dim(as.array(x)),dim(as.array(y)))

z <- outer(months,years,paste) # All month, year combinations pasted.
.KW algebra
.WR
